# CMakeList.txt: 顶层 CMake 项目文件，在此处执行全局配置
# 并包含子项目。
#
cmake_minimum_required (VERSION 3.8)
project ("cppproject")
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_BUILD_TYPE Debug CACHE STRING "set build tyoe to debug")
set(CMAKE_CXX_FLAGS_DEBUG "$ENV{CXXFLAGS} -O0 -Wall -g2 -ggdb")
set(CMAKE_CXX_FLAGS_RELEASE "$ENV{CXXFLAGS} -O3 -Wall")

# if(EXISTS ${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
#     include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
#     conan_basic_setup()
# endif()

set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/${CMAKE_BUILD_TYPE}/lib)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/${CMAKE_BUILD_TYPE}/lib)
SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/${CMAKE_BUILD_TYPE}/bin)
# 包含子项目。

add_subdirectory(3rdpart)
add_subdirectory(tests)
add_subdirectory("src")